<template>
  <a-card :bordered="false">
    <f-table ref="table" size="default" rowKey="versionId" :operator="operator" :columns="columns" :multiple="false"  :params="queryParam" :api="api.version">
      <span slot="action" slot-scope="text, record">
          <template>
            <a @click="$refs.materialsdetailDrawer.handleShow(record)">查看</a>
          </template>
        </span>
    </f-table>
    <materialsdetail-drawer ref="materialsdetailDrawer"></materialsdetail-drawer>
  </a-card>
</template>
<script>
  import MaterialsdetailDrawer from './materialsdetail_drawer'
  export default {
    components: { MaterialsdetailDrawer },
    props: {
      projectId: {
        type: String,
        default: ''
      }
    },
    data() {
      let me = this
      return {
        tableId: 'appUser',
        //列表初始化查询参数
        queryParam: { },
        // 表头
        columns: [
          {
            title: '版本号',
            align: 'center',
            dataIndex: 'bigVersion',
            width: 150
          },
          {
            title: '操作人',
            align: 'center',
            dataIndex: 'userName',
            width: 150
          },
          {
            title: '操作时间',
            align: 'center',
            dataIndex: 'createTime',
            width: 150
          },
          {
            title: '操作',
            align: 'center',
            scopedSlots: { customRender: 'action' },
            width: 100
          }
        ],
        operator: [
        ]
      }
    },
    created() {
      this.queryParam.projectId=this.projectId
    },
    methods: {
      // searchHandler(params) {
      //   this.$refs.table.refresh(true, params)
      // }
    }

  }
</script>
<style scoped>

</style>